<template>
    <div class="loading">
        <span>加载中</span>
        <ul>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
            <li></li>
        </ul>
    </div>
</template>

<style scoped>
.loading {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}
li {
    display: inline-block;
    list-style: none;
    width: 20px;
    height: 20px;
    background-color: #fff;
    border-radius: 50px;
    animation: animate 1.6s ease-in-out infinite;
}
@keyframes animate {
    0%, 40%, 100% {
        transform: scale(0.2);
    }
    20% {
        transform: scale(1);
    }
}
li:nth-child(1) {
    animation-delay: -1.4s;
    background-color: #ffff00;
    box-shadow: 0 0 50p #ffff00;
}
li:nth-child(2) {
    animation-delay: -1.2s;
    background-color: #76ff03;
    box-shadow: 0 0 50px #76ff03;
}
li:nth-child(3) {
    animation-delay: -1s;
    background-color: #f06292;
    box-shadow: 0 0 50px  #f06292;
}
li:nth-child(4) {
    animation-delay: -0.8s;
    background-color: #4fc3f7;
    box-shadow: 0 0 50px  #4fc3f7;
}
li:nth-child(5) {
    animation-delay: -0.6s;
    background-color: #ba68c8;
    box-shadow: 0 0 50px  #ba68c8;
}
li:nth-child(6) {
    animation-delay: -0.4s;
    background-color: #f57c00;
    box-shadow: 0 0 50px  #f57c00;
}
li:nth-child(7) {
    animation-delay: -0.2s;
    background-color: #673ab7;
    box-shadow: 0 0 50px  #673ab7;
}
</style>